<?php

include("../utility/connection.php");
include("../model/mBarang.php");
session_start();

if ($_SERVER["REQUEST_METHOD"] == "POST") {
    unset($_SESSION['startNum']);
    unset($_SESSION['endNum']);
    unset($_SESSION['curPage']);

    $startNum = trim(mysql_real_escape_string($_POST["hidStartNum"]));
    $endNum = trim(mysql_real_escape_string($_POST["hidEndNum"]));
    $curPage = trim(mysql_real_escape_string($_POST["hidCurPage"]));
    $_SESSION['startNum'] = $startNum;
    $_SESSION['endNum'] = $endNum;
    $_SESSION['curPage'] = $curPage;
    
    $pageName = trim(mysql_real_escape_string($_POST["hidPageName"]));
    header("location: ../".$pageName);
}
?>
